/*      */ package com.zimbra.cs.index.query.parser;
/*      */ 
/*      */ import java.io.InputStream;
/*      */ import java.io.Reader;
/*      */ import java.io.UnsupportedEncodingException;
/*      */ import java.util.ArrayList;
/*      */ import java.util.List;
/*      */ 
/*      */ 
/*      */ 
/*      */ 
/*      */ 
/*      */ 
/*      */ 
/*      */ 
/*      */ 
/*      */ 
/*      */ final class Parser
/*      */   implements ParserTreeConstants, ParserConstants
/*      */ {
/*   21 */   protected JJTParserState jjtree = new JJTParserState();
/*      */   public ParserTokenManager token_source;
/*      */   
/*      */   public final SimpleNode parse() throws ParseException {
/*   25 */     SimpleNode jjtn000 = new SimpleNode(0);
/*   26 */     boolean jjtc000 = true;
/*   27 */     this.jjtree.openNodeScope(jjtn000);
/*   28 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*   30 */       Query();
/*   31 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 0: 
/*      */       case 73: 
/*   34 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 73: 
/*   36 */           jj_consume_token(73);
/*   37 */           break;
/*      */         case 0: 
/*   39 */           jj_consume_token(0);
/*   40 */           break;
/*      */         default: 
/*   42 */           this.jj_la1[0] = this.jj_gen;
/*   43 */           jj_consume_token(-1);
/*   44 */           throw new ParseException();
/*      */         }
/*      */         break;
/*      */       default: 
/*   48 */         this.jj_la1[1] = this.jj_gen;
/*      */       }
/*      */       
/*   51 */       this.jjtree.closeNodeScope(jjtn000, true);
/*   52 */       jjtc000 = false;
/*   53 */       jjtn000.jjtSetLastToken(getToken(0));
/*   54 */       return jjtn000;
/*      */     } catch (Throwable jjte000) {
/*   56 */       if (jjtc000) {
/*   57 */         this.jjtree.clearNodeScope(jjtn000);
/*   58 */         jjtc000 = false;
/*      */       } else {
/*   60 */         this.jjtree.popNode();
/*      */       }
/*   62 */       if ((jjte000 instanceof RuntimeException)) {
/*   63 */         throw ((RuntimeException)jjte000);
/*      */       }
/*   65 */       if ((jjte000 instanceof ParseException)) {
/*   66 */         throw ((ParseException)jjte000);
/*      */       }
/*   68 */       throw ((Error)jjte000);
/*      */     } finally {
/*   70 */       if (jjtc000) {
/*   71 */         this.jjtree.closeNodeScope(jjtn000, true);
/*   72 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void Query()
/*      */     throws ParseException
/*      */   {
/*   80 */     SimpleNode jjtn000 = new SimpleNode(1);
/*   81 */     boolean jjtc000 = true;
/*   82 */     this.jjtree.openNodeScope(jjtn000);
/*   83 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*   85 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 71: 
/*      */       case 72: 
/*   88 */         SortBy();
/*   89 */         break;
/*      */       default: 
/*   91 */         this.jj_la1[2] = this.jj_gen;
/*      */       }
/*      */       
/*   94 */       Clause();
/*   95 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 71: 
/*      */       case 72: 
/*   98 */         SortBy();
/*   99 */         break;
/*      */       default: 
/*  101 */         this.jj_la1[3] = this.jj_gen;
/*      */       }
/*      */       
/*      */       for (;;)
/*      */       {
/*  106 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 3: case 5: 
/*      */         case 6: case 7: 
/*      */         case 8: case 9: 
/*      */         case 10: 
/*      */         case 13: 
/*      */         case 16: 
/*      */         case 17: 
/*      */         case 18: 
/*      */         case 19: 
/*      */         case 20: 
/*      */         case 21: 
/*      */         case 22: 
/*      */         case 23: 
/*      */         case 24: 
/*      */         case 25: 
/*      */         case 26: 
/*      */         case 27: 
/*      */         case 28: 
/*      */         case 29: 
/*      */         case 30: 
/*      */         case 31: 
/*      */         case 32: 
/*      */         case 33: 
/*      */         case 34: 
/*      */         case 35: 
/*      */         case 36: 
/*      */         case 37: 
/*      */         case 38: 
/*      */         case 39: 
/*      */         case 40: 
/*      */         case 43: 
/*      */         case 44: 
/*      */         case 45: 
/*      */         case 46: 
/*      */         case 47: 
/*      */         case 48: 
/*      */         case 49: 
/*      */         case 50: 
/*      */         case 51: 
/*      */         case 52: 
/*      */         case 53: 
/*      */         case 54: 
/*      */         case 55: 
/*      */         case 56: 
/*      */         case 57: 
/*      */         case 58: 
/*      */         case 59: 
/*      */         case 60: 
/*      */         case 61: 
/*      */         case 62: 
/*      */         case 63: 
/*      */         case 64: 
/*      */         case 65: 
/*      */         case 66: 
/*      */         case 67: 
/*      */         case 68: 
/*      */         case 69: 
/*      */         case 70: 
/*      */           break;
/*      */         case 4: case 11: 
/*      */         case 12: case 14: 
/*      */         case 15: case 41: 
/*      */         case 42: 
/*      */         default: 
/*  171 */           this.jj_la1[4] = this.jj_gen;
/*  172 */           break;
/*      */         }
/*  174 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 5: 
/*      */         case 6: 
/*  177 */           Conjunction();
/*  178 */           break;
/*      */         default: 
/*  180 */           this.jj_la1[5] = this.jj_gen;
/*      */         }
/*      */         
/*  183 */         Clause();
/*  184 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 71: 
/*      */         case 72: 
/*  187 */           SortBy();
/*  188 */           break;
/*      */         default: 
/*  190 */           this.jj_la1[6] = this.jj_gen;
/*      */         }
/*      */       }
/*      */     }
/*      */     catch (Throwable jjte000) {
/*  195 */       if (jjtc000) {
/*  196 */         this.jjtree.clearNodeScope(jjtn000);
/*  197 */         jjtc000 = false;
/*      */       } else {
/*  199 */         this.jjtree.popNode();
/*      */       }
/*  201 */       if ((jjte000 instanceof RuntimeException)) {
/*  202 */         throw ((RuntimeException)jjte000);
/*      */       }
/*  204 */       if ((jjte000 instanceof ParseException)) {
/*  205 */         throw ((ParseException)jjte000);
/*      */       }
/*  207 */       throw ((Error)jjte000);
/*      */     } finally {
/*  209 */       if (jjtc000) {
/*  210 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  211 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void Clause() throws ParseException
/*      */   {
/*  218 */     SimpleNode jjtn000 = new SimpleNode(2);
/*  219 */     boolean jjtc000 = true;
/*  220 */     this.jjtree.openNodeScope(jjtn000);
/*  221 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  223 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 7: 
/*      */       case 8: 
/*      */       case 9: 
/*  227 */         Modifier();
/*  228 */         break;
/*      */       default: 
/*  230 */         this.jj_la1[7] = this.jj_gen;
/*      */       }
/*      */       
/*  233 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 3: 
/*  235 */         jj_consume_token(3);
/*  236 */         Query();
/*  237 */         jj_consume_token(4);
/*  238 */         break;
/*      */       case 16: 
/*      */       case 17: 
/*      */       case 18: 
/*      */       case 19: 
/*      */       case 20: 
/*      */       case 21: 
/*      */       case 22: 
/*      */       case 23: 
/*      */       case 24: 
/*      */       case 25: 
/*      */       case 26: 
/*      */       case 27: 
/*      */       case 28: 
/*      */       case 29: 
/*      */       case 30: 
/*      */       case 31: 
/*      */       case 32: 
/*      */       case 33: 
/*      */       case 34: 
/*      */       case 35: 
/*      */       case 36: 
/*      */       case 37: 
/*      */       case 38: 
/*      */       case 39: 
/*      */       case 40: 
/*      */       case 55: 
/*      */       case 56: 
/*      */       case 57: 
/*      */       case 58: 
/*      */       case 59: 
/*      */       case 60: 
/*      */       case 61: 
/*      */       case 62: 
/*      */       case 63: 
/*      */       case 64: 
/*      */       case 65: 
/*      */       case 66: 
/*      */       case 67: 
/*      */       case 68: 
/*      */       case 69: 
/*  279 */         TextClause();
/*  280 */         break;
/*      */       case 70: 
/*  282 */         ItemClause();
/*  283 */         break;
/*      */       case 43: 
/*      */       case 44: 
/*      */       case 45: 
/*      */       case 46: 
/*      */       case 47: 
/*      */       case 48: 
/*      */       case 49: 
/*      */       case 50: 
/*      */       case 51: 
/*      */       case 52: 
/*      */       case 53: 
/*      */       case 54: 
/*  296 */         DateClause();
/*  297 */         break;
/*      */       case 10: 
/*      */       case 13: 
/*  300 */         DefaultClause();
/*  301 */         break;
/*      */       case 4: case 5: case 6: case 7: case 8: case 9: case 11: case 12: case 14: case 15: case 41: case 42: default: 
/*  303 */         this.jj_la1[8] = this.jj_gen;
/*  304 */         jj_consume_token(-1);
/*  305 */         throw new ParseException();
/*      */       }
/*      */     } catch (Throwable jjte000) {
/*  308 */       if (jjtc000) {
/*  309 */         this.jjtree.clearNodeScope(jjtn000);
/*  310 */         jjtc000 = false;
/*      */       } else {
/*  312 */         this.jjtree.popNode();
/*      */       }
/*  314 */       if ((jjte000 instanceof RuntimeException)) {
/*  315 */         throw ((RuntimeException)jjte000);
/*      */       }
/*  317 */       if ((jjte000 instanceof ParseException)) {
/*  318 */         throw ((ParseException)jjte000);
/*      */       }
/*  320 */       throw ((Error)jjte000);
/*      */     } finally {
/*  322 */       if (jjtc000) {
/*  323 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  324 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void DefaultClause() throws ParseException
/*      */   {
/*  331 */     SimpleNode jjtn000 = new SimpleNode(3);
/*  332 */     boolean jjtc000 = true;
/*  333 */     this.jjtree.openNodeScope(jjtn000);
/*  334 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  336 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 10: 
/*  338 */         jj_consume_token(10);
/*  339 */         break;
/*      */       case 13: 
/*  341 */         jj_consume_token(13);
/*  342 */         break;
/*      */       default: 
/*  344 */         this.jj_la1[9] = this.jj_gen;
/*  345 */         jj_consume_token(-1);
/*  346 */         throw new ParseException();
/*      */       }
/*      */     } finally {
/*  349 */       if (jjtc000) {
/*  350 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  351 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void TextClause() throws ParseException
/*      */   {
/*  358 */     SimpleNode jjtn000 = new SimpleNode(4);
/*  359 */     boolean jjtc000 = true;
/*  360 */     this.jjtree.openNodeScope(jjtn000);
/*  361 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  363 */       TextField();
/*  364 */       TextTerm();
/*      */     } catch (Throwable jjte000) {
/*  366 */       if (jjtc000) {
/*  367 */         this.jjtree.clearNodeScope(jjtn000);
/*  368 */         jjtc000 = false;
/*      */       } else {
/*  370 */         this.jjtree.popNode();
/*      */       }
/*  372 */       if ((jjte000 instanceof RuntimeException)) {
/*  373 */         throw ((RuntimeException)jjte000);
/*      */       }
/*  375 */       if ((jjte000 instanceof ParseException)) {
/*  376 */         throw ((ParseException)jjte000);
/*      */       }
/*  378 */       throw ((Error)jjte000);
/*      */     } finally {
/*  380 */       if (jjtc000) {
/*  381 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  382 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void ItemClause() throws ParseException
/*      */   {
/*  389 */     SimpleNode jjtn000 = new SimpleNode(5);
/*  390 */     boolean jjtc000 = true;
/*  391 */     this.jjtree.openNodeScope(jjtn000);
/*  392 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  394 */       jj_consume_token(70);
/*  395 */       ItemTerm();
/*      */     } catch (Throwable jjte000) {
/*  397 */       if (jjtc000) {
/*  398 */         this.jjtree.clearNodeScope(jjtn000);
/*  399 */         jjtc000 = false;
/*      */       } else {
/*  401 */         this.jjtree.popNode();
/*      */       }
/*  403 */       if ((jjte000 instanceof RuntimeException)) {
/*  404 */         throw ((RuntimeException)jjte000);
/*      */       }
/*  406 */       if ((jjte000 instanceof ParseException)) {
/*  407 */         throw ((ParseException)jjte000);
/*      */       }
/*  409 */       throw ((Error)jjte000);
/*      */     } finally {
/*  411 */       if (jjtc000) {
/*  412 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  413 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void DateClause() throws ParseException
/*      */   {
/*  420 */     SimpleNode jjtn000 = new SimpleNode(6);
/*  421 */     boolean jjtc000 = true;
/*  422 */     this.jjtree.openNodeScope(jjtn000);
/*  423 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  425 */       DateField();
/*  426 */       DateTerm();
/*      */     } catch (Throwable jjte000) {
/*  428 */       if (jjtc000) {
/*  429 */         this.jjtree.clearNodeScope(jjtn000);
/*  430 */         jjtc000 = false;
/*      */       } else {
/*  432 */         this.jjtree.popNode();
/*      */       }
/*  434 */       if ((jjte000 instanceof RuntimeException)) {
/*  435 */         throw ((RuntimeException)jjte000);
/*      */       }
/*  437 */       if ((jjte000 instanceof ParseException)) {
/*  438 */         throw ((ParseException)jjte000);
/*      */       }
/*  440 */       throw ((Error)jjte000);
/*      */     } finally {
/*  442 */       if (jjtc000) {
/*  443 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  444 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void TextField() throws ParseException {
/*  450 */     switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */     case 40: 
/*  452 */       jj_consume_token(40);
/*  453 */       break;
/*      */     case 18: 
/*  455 */       jj_consume_token(18);
/*  456 */       break;
/*      */     case 62: 
/*  458 */       jj_consume_token(62);
/*  459 */       break;
/*      */     case 68: 
/*  461 */       jj_consume_token(68);
/*  462 */       break;
/*      */     case 34: 
/*  464 */       jj_consume_token(34);
/*  465 */       break;
/*      */     case 64: 
/*  467 */       jj_consume_token(64);
/*  468 */       break;
/*      */     case 32: 
/*  470 */       jj_consume_token(32);
/*  471 */       break;
/*      */     case 63: 
/*  473 */       jj_consume_token(63);
/*  474 */       break;
/*      */     case 23: 
/*  476 */       jj_consume_token(23);
/*  477 */       break;
/*      */     case 22: 
/*  479 */       jj_consume_token(22);
/*  480 */       break;
/*      */     case 24: 
/*  482 */       jj_consume_token(24);
/*  483 */       break;
/*      */     case 20: 
/*  485 */       jj_consume_token(20);
/*  486 */       break;
/*      */     case 19: 
/*  488 */       jj_consume_token(19);
/*  489 */       break;
/*      */     case 25: 
/*  491 */       jj_consume_token(25);
/*  492 */       break;
/*      */     case 26: 
/*  494 */       jj_consume_token(26);
/*  495 */       break;
/*      */     case 27: 
/*  497 */       jj_consume_token(27);
/*  498 */       break;
/*      */     case 28: 
/*  500 */       jj_consume_token(28);
/*  501 */       break;
/*      */     case 17: 
/*  503 */       jj_consume_token(17);
/*  504 */       break;
/*      */     case 33: 
/*  506 */       jj_consume_token(33);
/*  507 */       break;
/*      */     case 16: 
/*  509 */       jj_consume_token(16);
/*  510 */       break;
/*      */     case 29: 
/*  512 */       jj_consume_token(29);
/*  513 */       break;
/*      */     case 65: 
/*  515 */       jj_consume_token(65);
/*  516 */       break;
/*      */     case 30: 
/*  518 */       jj_consume_token(30);
/*  519 */       break;
/*      */     case 66: 
/*  521 */       jj_consume_token(66);
/*  522 */       break;
/*      */     case 69: 
/*  524 */       jj_consume_token(69);
/*  525 */       break;
/*      */     case 67: 
/*  527 */       jj_consume_token(67);
/*  528 */       break;
/*      */     case 31: 
/*  530 */       jj_consume_token(31);
/*  531 */       break;
/*      */     case 21: 
/*  533 */       jj_consume_token(21);
/*  534 */       break;
/*      */     case 35: 
/*  536 */       jj_consume_token(35);
/*  537 */       break;
/*      */     case 36: 
/*  539 */       jj_consume_token(36);
/*  540 */       break;
/*      */     case 37: 
/*  542 */       jj_consume_token(37);
/*  543 */       break;
/*      */     case 38: 
/*  545 */       jj_consume_token(38);
/*  546 */       break;
/*      */     case 39: 
/*  548 */       jj_consume_token(39);
/*  549 */       break;
/*      */     case 58: 
/*  551 */       jj_consume_token(58);
/*  552 */       break;
/*      */     case 59: 
/*  554 */       jj_consume_token(59);
/*  555 */       break;
/*      */     case 60: 
/*  557 */       jj_consume_token(60);
/*  558 */       break;
/*      */     case 61: 
/*  560 */       jj_consume_token(61);
/*  561 */       break;
/*      */     case 55: 
/*  563 */       jj_consume_token(55);
/*  564 */       break;
/*      */     case 56: 
/*  566 */       jj_consume_token(56);
/*  567 */       break;
/*      */     case 57: 
/*  569 */       jj_consume_token(57);
/*  570 */       break;
/*      */     case 41: case 42: case 43: case 44: case 45: case 46: case 47: case 48: case 49: case 50: case 51: case 52: case 53: case 54: default: 
/*  572 */       this.jj_la1[10] = this.jj_gen;
/*  573 */       jj_consume_token(-1);
/*  574 */       throw new ParseException();
/*      */     }
/*      */   }
/*      */   
/*      */   private final void DateField() throws ParseException {
/*  579 */     switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */     case 43: 
/*  581 */       jj_consume_token(43);
/*  582 */       break;
/*      */     case 44: 
/*  584 */       jj_consume_token(44);
/*  585 */       break;
/*      */     case 45: 
/*  587 */       jj_consume_token(45);
/*  588 */       break;
/*      */     case 47: 
/*  590 */       jj_consume_token(47);
/*  591 */       break;
/*      */     case 46: 
/*  593 */       jj_consume_token(46);
/*  594 */       break;
/*      */     case 48: 
/*  596 */       jj_consume_token(48);
/*  597 */       break;
/*      */     case 49: 
/*  599 */       jj_consume_token(49);
/*  600 */       break;
/*      */     case 50: 
/*  602 */       jj_consume_token(50);
/*  603 */       break;
/*      */     case 53: 
/*  605 */       jj_consume_token(53);
/*  606 */       break;
/*      */     case 54: 
/*  608 */       jj_consume_token(54);
/*  609 */       break;
/*      */     case 51: 
/*  611 */       jj_consume_token(51);
/*  612 */       break;
/*      */     case 52: 
/*  614 */       jj_consume_token(52);
/*  615 */       break;
/*      */     default: 
/*  617 */       this.jj_la1[11] = this.jj_gen;
/*  618 */       jj_consume_token(-1);
/*  619 */       throw new ParseException();
/*      */     }
/*      */   }
/*      */   
/*      */   private final void Conjunction() throws ParseException
/*      */   {
/*  625 */     SimpleNode jjtn000 = new SimpleNode(8);
/*  626 */     boolean jjtc000 = true;
/*  627 */     this.jjtree.openNodeScope(jjtn000);
/*  628 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  630 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 5: 
/*  632 */         jj_consume_token(5);
/*  633 */         break;
/*      */       case 6: 
/*  635 */         jj_consume_token(6);
/*  636 */         break;
/*      */       default: 
/*  638 */         this.jj_la1[12] = this.jj_gen;
/*  639 */         jj_consume_token(-1);
/*  640 */         throw new ParseException();
/*      */       }
/*      */     } finally {
/*  643 */       if (jjtc000) {
/*  644 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  645 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void Modifier() throws ParseException
/*      */   {
/*  652 */     SimpleNode jjtn000 = new SimpleNode(9);
/*  653 */     boolean jjtc000 = true;
/*  654 */     this.jjtree.openNodeScope(jjtn000);
/*  655 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  657 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 8: 
/*  659 */         jj_consume_token(8);
/*  660 */         break;
/*      */       case 9: 
/*  662 */         jj_consume_token(9);
/*  663 */         break;
/*      */       case 7: 
/*  665 */         jj_consume_token(7);
/*  666 */         break;
/*      */       default: 
/*  668 */         this.jj_la1[13] = this.jj_gen;
/*  669 */         jj_consume_token(-1);
/*  670 */         throw new ParseException();
/*      */       }
/*      */     } finally {
/*  673 */       if (jjtc000) {
/*  674 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  675 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void DateModifier() throws ParseException
/*      */   {
/*  682 */     SimpleNode jjtn000 = new SimpleNode(10);
/*  683 */     boolean jjtc000 = true;
/*  684 */     this.jjtree.openNodeScope(jjtn000);
/*  685 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  687 */       jj_consume_token(7);
/*      */     } finally {
/*  689 */       if (jjtc000) {
/*  690 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  691 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void SortBy() throws ParseException
/*      */   {
/*  698 */     SimpleNode jjtn000 = new SimpleNode(11);
/*  699 */     boolean jjtc000 = true;
/*  700 */     this.jjtree.openNodeScope(jjtn000);
/*  701 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  703 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 71: 
/*  705 */         jj_consume_token(71);
/*  706 */         break;
/*      */       case 72: 
/*  708 */         jj_consume_token(72);
/*  709 */         break;
/*      */       default: 
/*  711 */         this.jj_la1[14] = this.jj_gen;
/*  712 */         jj_consume_token(-1);
/*  713 */         throw new ParseException();
/*      */       }
/*  715 */       jj_consume_token(10);
/*      */     } finally {
/*  717 */       if (jjtc000) {
/*  718 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  719 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void TextTerm() throws ParseException
/*      */   {
/*  726 */     SimpleNode jjtn000 = new SimpleNode(12);
/*  727 */     boolean jjtc000 = true;
/*  728 */     this.jjtree.openNodeScope(jjtn000);
/*  729 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  731 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 3: 
/*  733 */         jj_consume_token(3);
/*  734 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 7: 
/*      */         case 8: 
/*      */         case 9: 
/*  738 */           Modifier();
/*  739 */           break;
/*      */         default: 
/*  741 */           this.jj_la1[15] = this.jj_gen;
/*      */         }
/*      */         
/*  744 */         TextTerm();
/*      */         for (;;)
/*      */         {
/*  747 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 3: case 5: 
/*      */           case 6: 
/*      */           case 7: 
/*      */           case 8: 
/*      */           case 9: 
/*      */           case 10: 
/*      */           case 13: 
/*      */             break;
/*      */           case 4: case 11: 
/*      */           case 12: 
/*      */           default: 
/*  759 */             this.jj_la1[16] = this.jj_gen;
/*  760 */             break;
/*      */           }
/*  762 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 5: 
/*      */           case 6: 
/*  765 */             Conjunction();
/*  766 */             break;
/*      */           default: 
/*  768 */             this.jj_la1[17] = this.jj_gen;
/*      */           }
/*      */           
/*  771 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 7: 
/*      */           case 8: 
/*      */           case 9: 
/*  775 */             Modifier();
/*  776 */             break;
/*      */           default: 
/*  778 */             this.jj_la1[18] = this.jj_gen;
/*      */           }
/*      */           
/*  781 */           TextTerm();
/*      */         }
/*  783 */         jj_consume_token(4);
/*  784 */         break;
/*      */       case 10: 
/*  786 */         jj_consume_token(10);
/*  787 */         break;
/*      */       case 13: 
/*  789 */         jj_consume_token(13);
/*  790 */         break;
/*      */       default: 
/*  792 */         this.jj_la1[19] = this.jj_gen;
/*  793 */         jj_consume_token(-1);
/*  794 */         throw new ParseException();
/*      */       }
/*      */     } catch (Throwable jjte000) {
/*  797 */       if (jjtc000) {
/*  798 */         this.jjtree.clearNodeScope(jjtn000);
/*  799 */         jjtc000 = false;
/*      */       } else {
/*  801 */         this.jjtree.popNode();
/*      */       }
/*  803 */       if ((jjte000 instanceof RuntimeException)) {
/*  804 */         throw ((RuntimeException)jjte000);
/*      */       }
/*  806 */       if ((jjte000 instanceof ParseException)) {
/*  807 */         throw ((ParseException)jjte000);
/*      */       }
/*  809 */       throw ((Error)jjte000);
/*      */     } finally {
/*  811 */       if (jjtc000) {
/*  812 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  813 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void ItemTerm() throws ParseException
/*      */   {
/*  820 */     SimpleNode jjtn000 = new SimpleNode(13);
/*  821 */     boolean jjtc000 = true;
/*  822 */     this.jjtree.openNodeScope(jjtn000);
/*  823 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  825 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 3: 
/*  827 */         jj_consume_token(3);
/*  828 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 7: 
/*      */         case 8: 
/*      */         case 9: 
/*  832 */           Modifier();
/*  833 */           break;
/*      */         default: 
/*  835 */           this.jj_la1[20] = this.jj_gen;
/*      */         }
/*      */         
/*  838 */         ItemTerm();
/*      */         for (;;)
/*      */         {
/*  841 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 3: case 5: 
/*      */           case 6: 
/*      */           case 7: 
/*      */           case 8: 
/*      */           case 9: 
/*      */           case 10: 
/*      */           case 13: 
/*      */           case 15: 
/*      */             break;
/*      */           case 4: case 11: 
/*      */           case 12: case 14: 
/*      */           default: 
/*  854 */             this.jj_la1[21] = this.jj_gen;
/*  855 */             break;
/*      */           }
/*  857 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 5: 
/*      */           case 6: 
/*  860 */             Conjunction();
/*  861 */             break;
/*      */           default: 
/*  863 */             this.jj_la1[22] = this.jj_gen;
/*      */           }
/*      */           
/*  866 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 7: 
/*      */           case 8: 
/*      */           case 9: 
/*  870 */             Modifier();
/*  871 */             break;
/*      */           default: 
/*  873 */             this.jj_la1[23] = this.jj_gen;
/*      */           }
/*      */           
/*  876 */           ItemTerm();
/*      */         }
/*  878 */         jj_consume_token(4);
/*  879 */         break;
/*      */       case 10: 
/*  881 */         jj_consume_token(10);
/*  882 */         break;
/*      */       case 13: 
/*  884 */         jj_consume_token(13);
/*  885 */         break;
/*      */       case 15: 
/*  887 */         jj_consume_token(15);
/*  888 */         break;
/*      */       default: 
/*  890 */         this.jj_la1[24] = this.jj_gen;
/*  891 */         jj_consume_token(-1);
/*  892 */         throw new ParseException();
/*      */       }
/*      */     } catch (Throwable jjte000) {
/*  895 */       if (jjtc000) {
/*  896 */         this.jjtree.clearNodeScope(jjtn000);
/*  897 */         jjtc000 = false;
/*      */       } else {
/*  899 */         this.jjtree.popNode();
/*      */       }
/*  901 */       if ((jjte000 instanceof RuntimeException)) {
/*  902 */         throw ((RuntimeException)jjte000);
/*      */       }
/*  904 */       if ((jjte000 instanceof ParseException)) {
/*  905 */         throw ((ParseException)jjte000);
/*      */       }
/*  907 */       throw ((Error)jjte000);
/*      */     } finally {
/*  909 */       if (jjtc000) {
/*  910 */         this.jjtree.closeNodeScope(jjtn000, true);
/*  911 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */   private final void DateTerm() throws ParseException
/*      */   {
/*  918 */     SimpleNode jjtn000 = new SimpleNode(14);
/*  919 */     boolean jjtc000 = true;
/*  920 */     this.jjtree.openNodeScope(jjtn000);
/*  921 */     jjtn000.jjtSetFirstToken(getToken(1));
/*      */     try {
/*  923 */       switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */       case 3: 
/*  925 */         jj_consume_token(3);
/*  926 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 7: 
/*  928 */           DateModifier();
/*  929 */           break;
/*      */         default: 
/*  931 */           this.jj_la1[25] = this.jj_gen;
/*      */         }
/*      */         
/*  934 */         DateTerm();
/*      */         for (;;)
/*      */         {
/*  937 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 3: case 5: 
/*      */           case 6: 
/*      */           case 7: 
/*      */           case 8: 
/*      */           case 9: 
/*      */           case 10: 
/*      */           case 13: 
/*      */             break;
/*      */           case 4: case 11: 
/*      */           case 12: 
/*      */           default: 
/*  949 */             this.jj_la1[26] = this.jj_gen;
/*  950 */             break;
/*      */           }
/*  952 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 5: 
/*      */           case 6: 
/*  955 */             Conjunction();
/*  956 */             break;
/*      */           default: 
/*  958 */             this.jj_la1[27] = this.jj_gen;
/*      */           }
/*      */           
/*  961 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 7: 
/*  963 */             DateModifier();
/*  964 */             break;
/*      */           default: 
/*  966 */             this.jj_la1[28] = this.jj_gen;
/*      */           }
/*      */           
/*  969 */           DateTerm();
/*      */         }
/*  971 */         jj_consume_token(4);
/*  972 */         break;
/*      */       case 8: 
/*      */       case 9: 
/*      */       case 10: 
/*      */       case 13: 
/*  977 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 8: 
/*      */         case 9: 
/*  980 */           switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */           case 9: 
/*  982 */             jj_consume_token(9);
/*  983 */             break;
/*      */           case 8: 
/*  985 */             jj_consume_token(8);
/*  986 */             break;
/*      */           default: 
/*  988 */             this.jj_la1[29] = this.jj_gen;
/*  989 */             jj_consume_token(-1);
/*  990 */             throw new ParseException();
/*      */           }
/*      */           break;
/*      */         default: 
/*  994 */           this.jj_la1[30] = this.jj_gen;
/*      */         }
/*      */         
/*  997 */         switch (this.jj_ntk == -1 ? jj_ntk() : this.jj_ntk) {
/*      */         case 10: 
/*  999 */           jj_consume_token(10);
/* 1000 */           break;
/*      */         case 13: 
/* 1002 */           jj_consume_token(13);
/* 1003 */           break;
/*      */         default: 
/* 1005 */           this.jj_la1[31] = this.jj_gen;
/* 1006 */           jj_consume_token(-1);
/* 1007 */           throw new ParseException();
/*      */         }
/*      */         break;
/*      */       case 4: case 5: case 6: case 7: case 11: case 12: default: 
/* 1011 */         this.jj_la1[32] = this.jj_gen;
/* 1012 */         jj_consume_token(-1);
/* 1013 */         throw new ParseException();
/*      */       }
/*      */     } catch (Throwable jjte000) {
/* 1016 */       if (jjtc000) {
/* 1017 */         this.jjtree.clearNodeScope(jjtn000);
/* 1018 */         jjtc000 = false;
/*      */       } else {
/* 1020 */         this.jjtree.popNode();
/*      */       }
/* 1022 */       if ((jjte000 instanceof RuntimeException)) {
/* 1023 */         throw ((RuntimeException)jjte000);
/*      */       }
/* 1025 */       if ((jjte000 instanceof ParseException)) {
/* 1026 */         throw ((ParseException)jjte000);
/*      */       }
/* 1028 */       throw ((Error)jjte000);
/*      */     } finally {
/* 1030 */       if (jjtc000) {
/* 1031 */         this.jjtree.closeNodeScope(jjtn000, true);
/* 1032 */         jjtn000.jjtSetLastToken(getToken(0));
/*      */       }
/*      */     }
/*      */   }
/*      */   
/*      */ 
/*      */   SimpleCharStream jj_input_stream;
/*      */   
/*      */   public Token token;
/*      */   
/*      */   public Token jj_nt;
/*      */   
/*      */   private int jj_ntk;
/*      */   private int jj_gen;
/* 1046 */   private final int[] jj_la1 = new int[33];
/*      */   private static int[] jj_la1_0;
/*      */   private static int[] jj_la1_1;
/*      */   private static int[] jj_la1_2;
/*      */   
/* 1051 */   static { jj_la1_init_0();
/* 1052 */     jj_la1_init_1();
/* 1053 */     jj_la1_init_2();
/*      */   }
/*      */   
/* 1056 */   private static void jj_la1_init_0() { jj_la1_0 = new int[] { 1, 1, 0, 0, -55320, 96, 0, 896, -56312, 9216, -65536, 0, 96, 896, 0, 896, 10216, 96, 896, 9224, 896, 42984, 96, 896, 41992, 128, 10216, 96, 128, 768, 768, 9216, 9992 }; }
/*      */   
/*      */   private static void jj_la1_init_1() {
/* 1059 */     jj_la1_1 = new int[] { 0, 0, 0, 0, 63999, 0, 0, 0, 63999, 0, -8388097, 8386560, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
/*      */   }
/*      */   
/* 1062 */   private static void jj_la1_init_2() { jj_la1_2 = new int[] { 512, 512, 384, 384, 127, 0, 384, 0, 127, 0, 63, 0, 0, 0, 384, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; }
/*      */   
/*      */ 
/*      */ 
/*      */ 
/* 1067 */   public Parser(InputStream stream) { this(stream, null); }
/*      */   
/*      */   public Parser(InputStream stream, String encoding) {
/*      */     try {
/* 1071 */       this.jj_input_stream = new SimpleCharStream(stream, encoding, 1, 1); } catch (UnsupportedEncodingException e) { throw new RuntimeException(e); }
/* 1072 */     this.token_source = new ParserTokenManager(this.jj_input_stream);
/* 1073 */     this.token = new Token();
/* 1074 */     this.jj_ntk = -1;
/* 1075 */     this.jj_gen = 0;
/* 1076 */     for (int i = 0; i < 33; i++) { this.jj_la1[i] = -1;
/*      */     }
/*      */   }
/*      */   
/*      */ 
/* 1081 */   public void ReInit(InputStream stream) { ReInit(stream, null); }
/*      */   
/*      */   public void ReInit(InputStream stream, String encoding) {
/*      */     try {
/* 1085 */       this.jj_input_stream.ReInit(stream, encoding, 1, 1); } catch (UnsupportedEncodingException e) { throw new RuntimeException(e); }
/* 1086 */     this.token_source.ReInit(this.jj_input_stream);
/* 1087 */     this.token = new Token();
/* 1088 */     this.jj_ntk = -1;
/* 1089 */     this.jjtree.reset();
/* 1090 */     this.jj_gen = 0;
/* 1091 */     for (int i = 0; i < 33; i++) this.jj_la1[i] = -1;
/*      */   }
/*      */   
/*      */   public Parser(Reader stream)
/*      */   {
/* 1096 */     this.jj_input_stream = new SimpleCharStream(stream, 1, 1);
/* 1097 */     this.token_source = new ParserTokenManager(this.jj_input_stream);
/* 1098 */     this.token = new Token();
/* 1099 */     this.jj_ntk = -1;
/* 1100 */     this.jj_gen = 0;
/* 1101 */     for (int i = 0; i < 33; i++) this.jj_la1[i] = -1;
/*      */   }
/*      */   
/*      */   public void ReInit(Reader stream)
/*      */   {
/* 1106 */     this.jj_input_stream.ReInit(stream, 1, 1);
/* 1107 */     this.token_source.ReInit(this.jj_input_stream);
/* 1108 */     this.token = new Token();
/* 1109 */     this.jj_ntk = -1;
/* 1110 */     this.jjtree.reset();
/* 1111 */     this.jj_gen = 0;
/* 1112 */     for (int i = 0; i < 33; i++) this.jj_la1[i] = -1;
/*      */   }
/*      */   
/*      */   public Parser(ParserTokenManager tm)
/*      */   {
/* 1117 */     this.token_source = tm;
/* 1118 */     this.token = new Token();
/* 1119 */     this.jj_ntk = -1;
/* 1120 */     this.jj_gen = 0;
/* 1121 */     for (int i = 0; i < 33; i++) this.jj_la1[i] = -1;
/*      */   }
/*      */   
/*      */   public void ReInit(ParserTokenManager tm)
/*      */   {
/* 1126 */     this.token_source = tm;
/* 1127 */     this.token = new Token();
/* 1128 */     this.jj_ntk = -1;
/* 1129 */     this.jjtree.reset();
/* 1130 */     this.jj_gen = 0;
/* 1131 */     for (int i = 0; i < 33; i++) this.jj_la1[i] = -1;
/*      */   }
/*      */   
/*      */   private Token jj_consume_token(int kind) throws ParseException {
/*      */     Token oldToken;
/* 1136 */     if ((oldToken = this.token).next != null) this.token = this.token.next; else
/* 1137 */       this.token = (this.token.next = this.token_source.getNextToken());
/* 1138 */     this.jj_ntk = -1;
/* 1139 */     if (this.token.kind == kind) {
/* 1140 */       this.jj_gen += 1;
/* 1141 */       return this.token;
/*      */     }
/* 1143 */     this.token = oldToken;
/* 1144 */     this.jj_kind = kind;
/* 1145 */     throw generateParseException();
/*      */   }
/*      */   
/*      */ 
/*      */   public final Token getNextToken()
/*      */   {
/* 1151 */     if (this.token.next != null) this.token = this.token.next; else
/* 1152 */       this.token = (this.token.next = this.token_source.getNextToken());
/* 1153 */     this.jj_ntk = -1;
/* 1154 */     this.jj_gen += 1;
/* 1155 */     return this.token;
/*      */   }
/*      */   
/*      */   public final Token getToken(int index)
/*      */   {
/* 1160 */     Token t = this.token;
/* 1161 */     for (int i = 0; i < index; i++) {
/* 1162 */       if (t.next != null) t = t.next; else
/* 1163 */         t = t.next = this.token_source.getNextToken();
/*      */     }
/* 1165 */     return t;
/*      */   }
/*      */   
/*      */   private int jj_ntk() {
/* 1169 */     if ((this.jj_nt = this.token.next) == null) {
/* 1170 */       return this.jj_ntk = (this.token.next = this.token_source.getNextToken()).kind;
/*      */     }
/* 1172 */     return this.jj_ntk = this.jj_nt.kind;
/*      */   }
/*      */   
/* 1175 */   private List<int[]> jj_expentries = new ArrayList();
/*      */   private int[] jj_expentry;
/* 1177 */   private int jj_kind = -1;
/*      */   
/*      */   public ParseException generateParseException()
/*      */   {
/* 1181 */     this.jj_expentries.clear();
/* 1182 */     boolean[] la1tokens = new boolean[74];
/* 1183 */     if (this.jj_kind >= 0) {
/* 1184 */       la1tokens[this.jj_kind] = true;
/* 1185 */       this.jj_kind = -1;
/*      */     }
/* 1187 */     for (int i = 0; i < 33; i++) {
/* 1188 */       if (this.jj_la1[i] == this.jj_gen) {
/* 1189 */         for (int j = 0; j < 32; j++) {
/* 1190 */           if ((jj_la1_0[i] & 1 << j) != 0) {
/* 1191 */             la1tokens[j] = true;
/*      */           }
/* 1193 */           if ((jj_la1_1[i] & 1 << j) != 0) {
/* 1194 */             la1tokens[(32 + j)] = true;
/*      */           }
/* 1196 */           if ((jj_la1_2[i] & 1 << j) != 0) {
/* 1197 */             la1tokens[(64 + j)] = true;
/*      */           }
/*      */         }
/*      */       }
/*      */     }
/* 1202 */     for (int i = 0; i < 74; i++) {
/* 1203 */       if (la1tokens[i] != 0) {
/* 1204 */         this.jj_expentry = new int[1];
/* 1205 */         this.jj_expentry[0] = i;
/* 1206 */         this.jj_expentries.add(this.jj_expentry);
/*      */       }
/*      */     }
/* 1209 */     int[][] exptokseq = new int[this.jj_expentries.size()][];
/* 1210 */     for (int i = 0; i < this.jj_expentries.size(); i++) {
/* 1211 */       exptokseq[i] = ((int[])this.jj_expentries.get(i));
/*      */     }
/* 1213 */     return new ParseException(this.token, exptokseq, tokenImage);
/*      */   }
/*      */   
/*      */   public final void enable_tracing() {}
/*      */   
/*      */   public final void disable_tracing() {}
/*      */ }


/* Location:              /home/mint/zimbrastore.jar!/com/zimbra/cs/index/query/parser/Parser.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       0.7.1
 */